<div class="box grid_8 round_all" style="width:60%">
	<h2 class="box_head grad_colour">Thêm menu</h2>
	<a href="#" class="grabber">&nbsp;</a>
	<a href="#" class="toggle">&nbsp;</a>
	<div class="toggle_container">
		<div class="block">
			<form method="POST" action="<?php

echo site_url('menu/doCreateMenu')

?>">
				<label>Ngôn ngữ</label>
				<div class="input_group">
					<select name="ngonngu">
							<?php

foreach ($ngonngu as $row)
{
    $id = $row['id_ngonngu'];
    $language = $row['ngonngu'];
    echo "<option value=$id>$language
						              </option>";
}

?>
					</select>
				</div>
				<label>Tên menu</label> 
				<input name="tenmenu"id="notempty" title="Nhập tên menu" type="text" class="medium" value="<?php echo set_value('tenmenu')?>" autofocus> 
				
				<label>Loại menu</label>
				<div class="input_group">
					<select name="loaimenu">
						<option value="trongnuoc">
							Trang chủ
						</option>
						<option value="trongnuoc">
							Quảng cáo
						</option>
						<option value="quocte">
							Liên hệ
						</option>
						<option value="xahoi">
							Cấp tin tức
						</option>
						<option value="xahoi">
							Cấp video
						</option>
					</select>
				</div>
				
				<label>Thuộc menu</label>
				<div class="input_group">
					<select name="menucha">
                        <option value="0">Menu gốc</option>
                        <?php 
                        foreach($menu as $row)
                        {
                            $id=$row['id_menu'];
                            $name=$row['ten_menu'];
                            echo "<option value='$id'>$name</option>";
                        }
                        ?>
					</select>
				</div>
						
				<button onclick="submitForm('Form','Bạn có muốn thêm menu này?')" class="button_colour round_all"><?php

echo img(array(
    'src' => 'images/icons/small/white/Bended%20Arrow%20Right.png',
    'height' => '24',
    'width' => '24',
    'alt' => 'Bended Arrow Right'))

?><span>Thêm menu mới</span></button> 							
			</form>
			
			<script type="text/javascript"> 
	            var notempty = new LiveValidation('notempty');
				notempty.add( Validate.Presence );
                notempty.add( Validate.Length, { minimum: 5 } );
				var atleast = new LiveValidation('atleast');
				atleast.add( Validate.Length, { minimum: 5 } );
                
                function submitForm(formID, message){
                var form;
                form=document.getElementById(formID);
                if(confirm(message)) form.submit();    
                }
			</script>
		</div>
	</div>
</div>